﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ChurchDiary.TableEntity
{
    public class ProfileInfo
    {
        public string Name { get; set; }
        public string ProfileImage { get; set; }
        public string LastLogin { get; set; }
        public string DateFormate { get; set; }
        public string UsertypeName { get; set; }
        public string totallogincount { get; set; }
    }
    [Table("CH_RelationShip")]
    public class EntityRelationShip
    {
        [Key]
        public Guid RelationShipId { get; set; }
        public string RelationShipName { get; set; }
        /// <summary>
        /// 1.Married Member Relationship
        /// 2.Un Married Member Relationship
        /// </summary>
        public int MarriedFamily { get; set; }
        public int Status { get; set; }

        [NotMapped]
        public int TotalCounts { get; set; }
    }
    [Table("CH_NameTitle")]
    public class EntityNameTitle : BaseEntity
    {
        [Key]
        public Guid NameTitleId { get; set; }
        [MaxLength(16)]
        public string NameTitle { get; set; }
        [MaxLength(64)]
        public string NameDesc { get; set; }
        [NotMapped]
        public int TotalCounts { get; set; }
    }
    [Table("CH_Country")]
    public class EntityCountry
    {
        [Key]
        public Guid CountryId { get; set; }
        public string CountryName { get; set; }
        public int Status { get; set; }
    }
    [Table("CH_State")]
    public class EntityStates
    {
        [Key]
        public Guid StateId { get; set; }
        public Guid CountryId { get; set; }
        public string StateName { get; set; }
        public int Status { get; set; }

        public EntityCountry Country { get; set; }
    }
    [Table("CH_Comments")]
    public class EntityComments
    {
        [Key]
        public Guid CommentId { get; set; }
        public Guid CommentMapId { get; set; }
        public string Name { get; set; }
        public string EmailId { get; set; }
        public string PhoneNo { get; set; }
        public string Comment { get; set; }
        public int Status { get; set; }
    }
    [Table("CH_ControllerAction")]
    public class EntityControllerAction
    {
        [Key]
        public Guid ActionId { get; set; }
        [MaxLength(64)]
        public string Controller { get; set; }
        [MaxLength(64)]
        public string Action { get; set; }
        public string ReturnType { get; set; }
        public string Attributes { get; set; }
    }
    [Table("CH_Dateformat")]
    public class EntityDateFormat
    {
        [Key]
        public Guid DateFormateId { get; set; }
        public string DateFormatName { get; set; }
        public string DateFormatValue { get; set; }
        public string JqueryFormat { get; set; }
        public string CodeFormat { get; set; }
        public int IsDefault { get; set; }
    }

    [Table("CH_Language")]
    public class EntityLanguage : BaseEntity
    {
        [Key]
        public Guid LanguageId { get; set; }
        public string LanguageName { get; set; }
        public string LagnuageAbbrivation { get; set; }
        public int LanguageValue { get; set; }
    }

    [Table("CH_Documents")]
    public class EntityDocuments
    {
        [Key]
        public Guid DocumentId { get; set; }
        public string DocumentName { get; set; }
        public int Status { get; set; }

        [NotMapped]
        public int TotalCounts { get; set; }
    }

    [Table("CH_Email")]
    public class EntityEmail
    {
        [Key]
        public Guid EmailId { get; set; }
        public Guid EmailSourceId { get; set; }

        public string EmailFrom { get; set; }
        public string EmailToAddress { get; set; }
        public string EmailBcc { get; set; }
        public string EmailCC { get; set; }

        public string EmailSubject { get; set; }
        public string EmailContent { get; set; }
        public string EmailType { get; set; }
        
        public Guid EmailCreatedBy { get; set; }
        public DateTime? EmailCreatedOn { get; set; }
        /// <summary>
        /// 0.Pending
        /// 1.Send Successfully
        /// 2.Sending Failed
        /// 3.Send Later
        /// </summary>
        public int EmaiStatus { get; set; }
        public DateTime? EmailSendOn { get; set; }

        public List<EntityEmailAttachments> EmailAttachments { get; set; }
    }

    [Table("CH_EmailAttachments")]
    public class EntityEmailAttachments
    {
        [Key]
        public Guid AttactmentId { get; set; }
        public Guid EmailId { get; set; }
        public string Acttachmentlinks { get; set; }
    }



    public class FullEntityEmailTemplate
    {
        public EntityEmailTemplate EmailTemplate { get; set; }
        public EntityUser User { get; set; }
        public EntityOrganizationInfo OrganizationInfo { get; set; }
        public EntitySoftwareInfo SoftwareInfo { get; set; }
        public EntityFullIntialSettings IntialSettings { get; set; }
    }
    
}
